<?php

namespace common\models\shop;

use yii\db\ActiveRecord;

/**
 * Desc 店铺收银订单
 */
class Order extends ActiveRecord {
    
    //状态-待支付
    const STATUS_WAIT = 1;
    //状态-已支付
    const STATUS_PAID = 2;
    //状态-已取消
    const STATUS_CANCEL = 3;
    //状态-部分退款
    const STATUS_REFUND_PART = 4;
    //状态-全部退款
    const STATUS_REFUND_FULL = 5;
    

    public static $status = [
        self::STATUS_WAIT => '待支付',
        self::STATUS_PAID => '已支付',
        self::STATUS_CANCEL => '已取消',
        self::STATUS_REFUND_PART => '部分退款',
        self::STATUS_REFUND_FULL => '全额退款',
    ];
    

    /**
     * {@inheritdoc}
     */
    public static function tableName() {
        return '{{%pay_order}}';
    }

}
